package com.ruibang.glass.quality.entity;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDateTime;

/**
 * <p>
 * 半成品挠度信息
 * </p>
 *
 * @author wujie
 * @since 2024-03-11
 */

@ApiModel(value = "半成品挠度信息")
@TableName("g_quality_deflect")
@Data
public class QualityDeflect {

    @ApiModelProperty(value = "挠度ID")
    @TableId(value = "deflect_id", type = IdType.ASSIGN_ID)
    private String deflectId;
    @ApiModelProperty(value = "所属产线")
    private String productLine;
    @ApiModelProperty(value = "玻璃ID")
    private String glassId;
    @ApiModelProperty(value = "玻璃类型(1:成品,2:半成品)")
    private String glassType;
    @ApiModelProperty(value = "产品型号(G8.5,G8.6,G8.6+,G8.7)")
    private String glassModel;
    @ApiModelProperty(value = "检查规格")
    private String checkRule;
    @ApiModelProperty(value = "确认人")
    private String userId;
    @ApiModelProperty(value = "记录日期")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime recordTime;
    @ApiModelProperty(value = "横切时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime transectTime;
    @ApiModelProperty(value = "班次(白班day,中班night)")
    private String team;
    @ApiModelProperty(value = "判定(合格:0,不合格:1)")
    private String decide;
    @ApiModelProperty(value = "挠度规格(≤20mm)")
    private Integer deflectSpecification;
    @ApiModelProperty(value = "备注")
    private String remark;
    @ApiModelProperty(value = "是否删除(1:是,0:否)")
    @TableLogic
    private String isDelete;

    @ApiModelProperty(value = "产线名称")
    private String productLineName;

    @ApiModelProperty(value = "用户名称")
    @TableField(exist = false)
    private String userName;

    @ApiModelProperty(value = "规则信息")
    @TableField(exist = false)
    private SpecsConfig specsConfig;
}
